<!DOCTYPE html>
<html>
  <head>
    <meta charset="UTF-8">
    <title>Document</title>
  </head>
  <body>
    <script>
      var arr = [];	   	  // 创建一维空数组
      for (var i = 0; i < 3; i++) {
        arr[i] = []; 		  // 将当前元素设置为数组
        arr[i][0] = i;	  // 为二维数组元素赋值
      }
    </script>
  </body>
</html>